<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <title>layout 管理系统大布局 - Layui</title>
  <link rel="stylesheet" href="layui/css/layui.css">
</head>
<body>
<div class="layui-layout layui-layout-admin">
  <div class="layui-header">
    <div class="layui-logo layui-hide-xs layui-bg-black">绵阳城市学院</div>
    <!-- 头部区域（可配合layui 已有的水平导航） -->
    <ul class="layui-nav layui-layout-left">
      <!-- 移动端显示 -->
      <li class="layui-nav-item layui-show-xs-inline-block layui-hide-sm" lay-header-event="menuLeft">
        <i class="layui-icon layui-icon-spread-left"></i>
      </li>

      <li class="layui-nav-item layui-hide-xs"><a href="">绵阳城市学院图书管理系统欢迎你</a></li>
    </ul>
    <ul class="layui-nav layui-layout-right">
      <li class="layui-nav-item layui-hide layui-show-md-inline-block">
        <a href="javascript:" class="username">
          <img src="//tva1.sinaimg.cn/crop.0.0.118.118.180/5db11ff4gw1e77d3nqrv8j203b03cweg.jpg" class="layui-nav-img">
          tester
        </a>
        <dl class="layui-nav-child">
          <dd><a href="">Your Profile</a></dd>
          <dd><a href="">Settings</a></dd>
          <dd><a href="login.html">Sign out</a></dd>
        </dl>
      </li>
      <li class="layui-nav-item"lay-header-event="menuRight"lay-unselect>
        <a href="javascript:;">
          <i class="layui-icon layui-icon-more-vertical"></i>
        </a>
      </li>
    </ul>
  </div>

  <div class="layui-side layui-bg-black">
    <div class="layui-side-scroll">
      <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
      <ul class="layui-nav layui-nav-tree" lay-filter="test">
        <li class="layui-nav-item layui-nav-itemed">
          <a class="" href="javascript:;">图书管理</a>
          <dl class="layui-nav-child">
            <dd id="all"><a href="book.html" target="iframename">删除图书</a></dd>
            <dd><a href="search.html" target="iframename" >查找图书</a></dd>
            <dd><a href="addBook.html" target="iframename">增加图书</a></dd>
            <dd><a href="classify.html" target="iframename">图书分类查询</a></dd>
            <dd><a href="update.html" target="iframename">修改图书信息</a></dd>
          </dl>
        </li>
        <li class="layui-nav-item">
          <a href="javascript:;">图书</a>
          <dl class="layui-nav-child">
            <dd><a href="allbook.html" target="iframename">查看所有图书</a></dd>
          </dl>
        </li>
      </ul>
    </div>
  </div>

  <div class="layui-body">
    <!-- 内容主体区域 -->
    <iframe name="iframename" id="iframename" src="main.html" width="100%" height="100%">
    </iframe>
  </div>

  <div class="layui-footer" style="text-align: center">
    <img src="picture/4.jpg" width="200">
  </div>
</div>
<script src="layui/layui.js"></script>
<script>
  //JS
  layui.use(['element', 'layer',], function(){
    const element = layui.element
            , layer = layui.layer
            , $ = layui.$;
    //头部事件
  });
  let username = document.querySelector(".username");
  username.innerHTML=localStorage.getItem("username")
</script>
</body>
</html>